# -*- coding: utf-8 -*-
#__author__ = '风中的思绪'

from openerp import models, fields


class ConfigurationCommonType(models.Model):
    _name = "configuration.common.type"
    _rec_name = "value_name"

    # columns
    type_code = fields.Many2one('configuration.common.type', '上级类别',
                                # required=True,
                                select=True,
                                # domain="[('is_system', '=', 'True')]"
                                )
    value_code = fields.Char(string="编码", size=50, required=True)
    value_name = fields.Char(string="名称", size=200, required=True)
    value_group = fields.Char(string="分组", size=50)
    function_module = fields.Char(string="功能模块", size=50)
    remark = fields.Text(string="备注")
    # is_system = fields.Boolean(string="是否上级类别")
    order_no = fields.Integer(string="顺序")
    usable = fields.Boolean(string="是否可用", default=True)

